<?php

namespace app\admin\validate;

use think\Validate;

class ModelValidate extends Validate
{
    protected $rule =   [
        'brandId' => 'require',
        'name' => 'require',
        'typeName' => 'require',
        'sort' => 'require',
    ];

    protected $message = [
        'brandId.require' => '缺少参数brandId',
        'name.require' => '缺少参数name',
        'typeName.require' => '缺少参数typeName',
        'sort.require' => 'sort',
    ];

    protected $scene = [
        'add' => ['brandId', 'name', 'typeName', 'sort'],
    ];
}